package com.spogher.components.dropdownChoices;

import java.util.List;

import org.apache.wicket.markup.html.form.DropDownChoice;
import org.apache.wicket.markup.html.form.IChoiceRenderer;

import com.spogher.bsc.data.dataobjects.Team;

public class TeamDropDownChoice extends DropDownChoice<Team>{

	private static final long serialVersionUID = 1L;

	public TeamDropDownChoice(String id, List<Team> choices) {
		super(id, choices, new IChoiceRenderer<Team>() {

			private static final long serialVersionUID = 1L;

			public Object getDisplayValue(Team object) {
				return object.getName();
			}

			public String getIdValue(Team object, int index) {
				return object.getName();
			}
		});			
	}

}
